package com.uam.db.model.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;

/**
 * @author uam
 * @create 2023/12/3 15:05
 * @email uam@uam.com
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("TASK_V2")
public class Task {
    /**
     * 任务ID
     */
    @TableId(value = "ID", type = IdType.AUTO)
    private Long id;
    /**
     * 任务名称
     */
    @TableField(value = "NAME")
    private String name;
    /**
     * 任务状态，0：待起飞、1：飞行中、2：避让、3：降落、4：完成、5：拒绝、6：取消
     */
    @TableField(value = "STATUS")
    private Integer status;
    /**
     * gis相关信息
     */
    @TableField(value = "SETTTINGS")
    private String setttings;
    /**
     * 开始时间
     */
    @TableField(value = "START_TIME")
    private LocalDateTime startTime;
    /**
     * 结束时间
     */
    @TableField(value = "MODE")
    private Integer mode;
    /**
     * 创建人id
     */
    @TableField(value = "AUTHOR_ID")
    private Integer authorId;
    /**
     * 创建人名称
     */
    @TableField(value = "AUTHOR_NAME")
    private String authorName;
    /**
     * 创建时间
     */
    @TableField(value = "CREATE_TIME")
    private LocalDateTime createTime;
    /**
     * 更新时间
     */
    @TableField(value = "UPDATE_TIME")
    private LocalDateTime updateTime;
    /**
     * 结束时间
     */
    @TableField(value = "END_TIME")
    private LocalDateTime endTime;
    /**
     * 预计飞行距离
     */
    @TableField(value = "PREDICT_DISTANCE")
    private Double predictDistance;
    /**
     * 实际飞行距离
     */
    @TableField(value = "ACTUAL_DISTANCE")
    private Double actualDistance;
    /**
     * 预计飞行时间
     */
    @TableField(value = "PREDICT_COST")
    private Double predictCost;
    /**
     * 实际飞行时间
     */
    @TableField(value = "ACTUAL_COST")
    private Double actualCost;
    /**
     * 飞行器ID
     */
    @TableField(value = "AIRCRAFT_ID")
    private Integer aircraftId;
    /**
     * 出发点id
     */
    @TableField(value = "START_ID")
    private Long startId;
    /**
     * 目的地id
     */
    @TableField(value = "DESTINATION_ID")
    private Long destinationId;


    @TableField(value = "rectangle_point")
    private String rectanglePoint;
}
